#if !defined MODREGISTRY_H
#define MODREGISTRY_H

extern bool UEGetValue(HKEY KeyRoot,CString keyName,CString ValueName,CString& DefValue);
extern int UEGetSettingInstallNumber(CString key,int  defValue=-1);
extern void UESaveSettingInstallNumber(CString key,int  defValue);
extern bool RegSetValueEx(HKEY KeyRoot,CString keyName,CString ValueName,CString regValue);

CString GetAnyRegKey(LPCTSTR pszKey, LPCTSTR pszName,const CString Default="");
CString	GetRegKey(LPCTSTR pszKey, LPCTSTR pszName,const CString Default="");
float	    GetRegKey(LPCTSTR pszKey, LPCTSTR pszName,const float Default=0.0);
long		GetRegKey(LPCTSTR pszKey, LPCTSTR pszName,const long Default=0);
bool		GetRegKey(LPCTSTR pszKey, LPCTSTR pszName,const bool Default=false);
int	    	GetRegKey(LPCTSTR pszKey, LPCTSTR pszName,const int Default);

void SetRegValue(LPCTSTR pszKey, LPCTSTR pszName, const CString vValue);
void SetRegValue(LPCTSTR pszKey, LPCTSTR pszName,  const int vValue);
void SetRegValue(LPCTSTR pszKey, LPCTSTR pszName, const float vValue);
void SetRegValue(LPCTSTR pszKey, LPCTSTR pszName, const double vValue);
void SetRegValue(LPCTSTR pszKey, LPCTSTR pszName, const bool vValue);

extern bool GetPos( CString frmName,CRect& wndRect);
extern void SavePos(CWnd* frm,CString frmName);
#endif